package interfaces;

import java.util.Map;

import basic.QuerySet;
import basic.ResultSet;
import entities.TLogic;
import views.VLogicTransaction;

public interface ILogicService {

	//根据主键判断唯一对象是否存在
	public Boolean exist(String primaryKey) throws Exception;
	
	//根据动态条件查询唯一对象是否存在
	public Boolean contain(Map<String,Object> paramMap) throws Exception;

	//根据主键获取唯一对象
	public TLogic fetch(String primaryKey) throws Exception;
	
	//根据查询条件获取唯一对象
	public TLogic single(Map<String,Object> paramMap) throws Exception;

	//对新增或者修改的对象进行自动判断并持久化,返回包含主键和未更新属性的完整对象
	public TLogic persist(TLogic entityBean) throws Exception;

	//根据主键删除业务对象
	public Integer remove(String primaryKey ) throws Exception;
	
	//根据动态条件删除业务对象
	public Integer expunge(Map<String,Object> paramMap) throws Exception;
	
	//根据动态条件返回指定列聚合总数
	public Double summary(QuerySet<Object> querySet) throws Exception;

	//根据查询条件返回结果记录数
	public Integer record(Map<String,Object> paramMap) throws Exception;

	//根据动态条件进行数据库检索
	public  ResultSet<TLogic> search(QuerySet<Object> querySet) throws Exception;
	
	public Boolean possess(Map<String,Object> paramMap) throws Exception;
	
	public VLogicTransaction solely(Map<String,Object> paramMap) throws Exception;
	
	public  ResultSet<VLogicTransaction> relate(QuerySet<Object> querySet) throws Exception;
	
}
